package com.anxinr.service;

import com.anxinr.pojo.dto.OrderDTO;
import com.anxinr.pojo.entity.Order;
import com.anxinr.pojo.entity.OrderGoods;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;


/**
 * 订单模块
 * @author anxinr
 */
public interface OrderService extends IService<Order> {

    /**
     * 用户下单
     * @param orderDTO
     * @return void
     */
    void saveOrderInfo(OrderDTO orderDTO);

    /**
     * 我的订单
     * @param id
     * @return List<OrderDTO>
     */
    List<OrderDTO> getMyOrder(Long id);

    /**
     * 订单详细信息
     * @Param id
     * @return OrderGoods
     */
    OrderGoods myOrderDetail(Long id);

    /**
     * 配送订单
     * @Param orderId
     */
    void sendOrder(Long orderId);

    /**
     * 已完成订单
     * @Param orderId
     */
    void successOrder(Long orderId);
}
